package com.homework.wokr05;

public class Father01 {
    public Father01(){
        System.out.println("父类构造器");
    }
    public void have(){
        System.out.println("我有一头小毛驴，我从来也不骑");
    }
}
class Son01 extends  Father01{
    public Son01(){
        super();//不写，系统默认提供
        System.out.println("子类构造器");
    }
    public void have(){
        System.out.println("驴肉火烧，驴肉宴");
    }

    /*程序入口*/
    public static void main(String[] args) {
        Son01 son = new Son01();
        son.have();
    }
}
